package org.hy.user.action;

import java.util.HashMap;
import java.util.List;

import org.hy.user.UserModel;
import org.hy.user.service.UserService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;

@Controller
public class UserAction {

	@Autowired
    @Qualifier("userService")
	private UserService userService;
	
	
	@RequestMapping(value = "/user/userAction")
	public void saveUser() {
		
		userService.addUser(new HashMap<String, String>());
		
		List<UserModel> models = userService.getAllUser();
		
		System.out.println(models.size());
		
	}
	
}
